using INTEX.DataBase;
using ReflectionStudio.Core.Events;
using System;
using System.Data;
using System.Windows;
using System.Windows.Data;
namespace WPFExcelReport
{
    public partial class VABAUFM : ViewModelBase
    {  
     
        public VABAUFM()
            : base()
        { 
             switch (app.company)
            {
                    default:
                    case "YGR":
                    case "YCC":
                    case "TST":
                    SetEnv = new YGRDB();
                    SetData = new YGRDB();
                    SetProd = new YGRDB();
                    break; 
                 case "JLT":
                    SetEnv = new JLTDB();
                    SetData = new JLTDB();
                    SetProd = new JLTDB();
                    break;
            }
            TableName = "ABAUFM"; 
        } 
     }
    public partial class VABAUFM
    {
        public readonly static VABAUFM Instance = new VABAUFM();
        private string _VKAUF; public string VKAUF { get { return _VKAUF; } set { _VKAUF = value; OnPropertyChanged("VKAUF", value); } }
        public int ABALEAPOS
        {
            get;
            set;
        }

        private bool _FTMU;
        public bool FTMU
        {
            get { return _FTMU; }
            set { _FTMU = value; OnPropertyChanged("FTMU", value); }
        }
        public VVKPOS VVKP
        {
            get
            {
                if (!ENVMAIN.ContainsKey("VVKP"))
                    ENVMAIN["VVKP"] = new VVKPOS();
                return (VVKPOS)ENVMAIN["VVKP"];
            }
        }
        public VABPOS VABP
        {
            get
            {
                if (!ENVMAIN.ContainsKey("VABP"))
                    ENVMAIN["VABP"] = new VABPOS();
                return (VABPOS)ENVMAIN["VABP"];
            }
        }
        public VABFOLGE VABF
        {
            get
            {
                if (!ENVMAIN.ContainsKey("VABF"))
                    ENVMAIN["VABF"] = new VABFOLGE();
                return (VABFOLGE)ENVMAIN["VABF"];
            }
        }
        public VGAAUF GD
        {
            get
            {
                if (!ENVMAIN.ContainsKey("GD"))
                    ENVMAIN["GD"] = new VGAAUF();
                return (VGAAUF)ENVMAIN["GD"];
            }
        }
        public VWDECK WD
        {
            get
            {
                if (!ENVMAIN.ContainsKey("WD"))
                    ENVMAIN["WD"] = new VWDECK();
                return (VWDECK)ENVMAIN["WD"];
            }
        }

    }
}
